<html>

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>数据类型</title>
</head>

<body>
    <script>
        //  undefined
        var x;
        // alert(x)
        console.log(x);
        var strl = "hello world";
        var str2 = 'hello world';
        console.log(strl);
        console.log(str2);
        // var str ="hello world';
        var str3='田云芳："惊鸿宴"';
        console.log(str3);

        //字符串替换
        var str ="Java";
        //1. 下面代码执行顺序 先执行等候右侧代码 然后赋值给左边变量
        //2.js字符串的加法是拼接字符串
        str =str+"script";//放到左侧str过程中str中Java被删掉 新的JavaScript放入
        console.log(str);


    </script>
</body>
</html>